*Need to specify which model: 1=base, 2=added province-trend, 10=provincial quadratic trend.

u "C:\Users\townsend-j\Dropbox\min wage distr\JOLE revision\RESULTS_in_paper\Cengiz\Cengiz_5_year_all",clear

local e=.642 /*Pre-treatment average employment rate */


replace est=est/`e'
replace high=high/`e'
replace low=low/`e'
replace cum=cum/`e'

twoway ( bar est bin  , fcolor(ltblue) lcolor(none) ) ///
				(rcap low  high bin  , lcolor(ltblue*1.25) lwidth(thick) )  ///
				(line cum bin, lcolor(red*.33) lpat(line) lwidth(thick) ) 		, ///
				  xlabel(-4 "-4"  -2 "-2"  0 "0"  2 "2"  4 "4" 6 "6" 8 "8" 10 "10" 12 "12" 14 "14" 17 "17+" ) ///
				  ///
				ylabel(, labsize(medsmall)) scheme(s1color) /*xtitle("Wage Bin")*/ xtitle("Wage bins in `=char(36)' relative to new MW", size(medsmall)) xsc(titlegap(*10)) ytitle("Difference between actual and counterfactual employment" "count relative to the pre-treatment total employment", size(small))   ///
				 legend(off) 

 graph export "C:\Users\townsend-j\Dropbox\min wage distr\JOLE revision\RESULTS_in_paper\Cengiz\Cengiz_5_year_all.pdf",replace
				 
				 
u "C:\Users\townsend-j\Dropbox\min wage distr\JOLE revision\RESULTS_in_paper\Cengiz\Cengiz_stayers_1_year",clear

local e=.607 /*Pre-treatment average employment rate */


replace est=est/`e'
replace high=high/`e'
replace low=low/`e'
replace cum=cum/`e'

twoway ( bar est bin  , fcolor(ltblue) lcolor(none) ) ///
				(rcap low  high bin  , lcolor(ltblue*1.25) lwidth(thick) )  ///
				(line cum bin, lcolor(red*.33) lpat(line) lwidth(thick) ) 		, ///
				  xlabel(-4 "-4"  -2 "-2"  0 "0"  2 "2"  4 "4" 6 "6" 8 "8" 10 "10" 12 "12" 14 "14" 17 "17+" ) ///
				  ///
				ylabel(, labsize(medsmall)) scheme(s1color) /*xtitle("Wage Bin")*/ xtitle("Wage bins in `=char(36)' relative to new MW", size(medsmall)) xsc(titlegap(*10)) ytitle("Difference between actual and counterfactual incumbant employment" "count relative to the pre-treatment total employment", size(small))   ///
				 legend(off) 

 graph export "C:\Users\townsend-j\Dropbox\min wage distr\JOLE revision\RESULTS_in_paper\Cengiz\Cengiz_stayers_1_year.pdf",replace
				 
u "C:\Users\townsend-j\Dropbox\min wage distr\JOLE revision\RESULTS_in_paper\Cengiz\Cengiz_joiners_1_year",clear

local e=.039 /*Pre-treatment average employment rate */


replace est=est/`e'
replace high=high/`e'
replace low=low/`e'
replace cum=cum/`e'

twoway ( bar est bin  , fcolor(ltblue) lcolor(none) ) ///
				(rcap low  high bin  , lcolor(ltblue*1.25) lwidth(thick) )  ///
				(line cum bin, lcolor(red*.33) lpat(line) lwidth(thick) ) 		, ///
				  xlabel(-4 "-4"  -2 "-2"  0 "0"  2 "2"  4 "4" 6 "6" 8 "8" 10 "10" 12 "12" 14 "14" 17 "17+" ) ///
				  ///
				ylabel(, labsize(medsmall)) scheme(s1color) /*xtitle("Wage Bin")*/ xtitle("Wage bins in `=char(36)' relative to new MW", size(medsmall)) xsc(titlegap(*10)) ytitle("Difference between actual and counterfactual entrant employment" "count relative to the pre-treatment total employment", size(small))   ///
				 legend(off) 

 graph export "C:\Users\townsend-j\Dropbox\min wage distr\JOLE revision\RESULTS_in_paper\Cengiz\Cengiz_joiners_1_year.pdf",replace
				 
				 				 
				 				 
				 
				 
foreach model of numlist 1  {

twoway ( bar est bin, fcolor(ltblue) lcolor(none) ylabel(-.025(.01).025) )  ///
				(rcap low  high bin , lcolor(ltblue*1.25) lwidth(thick) ), ///
				(line cum bin, lcolor(red*.33) lpat(line) lwidth(thick) ), 	///
				 xlabel(-4 "-4"  -2 "-2"  0 "0"  2 "2"  4 "4" 6 "6" 8 "8" 10 "10" 12 "12" 14 "14" 17 "17+" ) ///
				ylabel(, labsize(medsmall)) scheme(s1color) /*xtitle("Wage Bin")*/ xtitle("Wage bins in `=char(36)' relative to new MW", size(medsmall)) xsc(titlegap(*10)) ytitle("Difference between actual and counterfactual empoloyment count relative to the pre-treatment total employment", height(10))   ///
				 legend(off) 
if `model'==1 {
local version="base"	
}
if `model'==2 {
local version="trend"	
}
if `model'== 10 {
local version="quadratic"
}
				 
 graph export "C:\Users\jimt2\Dropbox\min wage distr\JOLE revision\RESULTS_in_paper\Cengiz\Cengiz_5_year_prov_`version'.pdf",replace
}

				(line cum bin, lcolor(red*.33) lpat(line) lwidth(thick) ), 	///